package com.haier.nengyuan.myapplication;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;

public class PayElectricityBillActivity extends BaseActivity implements View.OnClickListener {
    private ImageView mTitleLeft;
    private TextView mTitleCenter;
    private TextView mTitleRight;
    private Button mBtNextPay;


    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_pay_electricity_bill);
        initViews();
        initDatas();
    }

    private void initDatas() {
        mTitleCenter.setText("电费缴费");
        mTitleRight.setText("");
    }

    private void initViews() {
        mTitleLeft = (ImageView) findViewById(R.id.title_left_black);
        mTitleCenter = (TextView) findViewById(R.id.title_center);
        mTitleRight = (TextView) findViewById(R.id.title_right);
        mBtNextPay = (Button) findViewById(R.id.bt_next_pay);
        mTitleLeft.setOnClickListener(this);
        mBtNextPay.setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        int id = v.getId();
        if (id == R.id.title_left_black) {
            finish();
        }
        if (id == R.id.bt_next_pay) {
            Intent intent = new Intent(PayElectricityBillActivity.this, PaymentActivity.class);
            PayElectricityBillActivity.this.startActivity(intent);
        }

    }
}
